#pragma once
/*
 *  MyDocument.h
 *  NXTFace
 *
 *  Created by David Giovannini on 8/23/06.
 *  Copyright 2006 Software by Jove. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License as
 * published by the Free Software Foundation; either version 2 of the
 * License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
 * USA
 */

#import <Cocoa/Cocoa.h>

namespace SBJ
{
namespace NXT
{
class Device;
}
}

@class NxtOutput;
@class NxtInput;

@interface NxtDevice : NSObject
{
	SBJ::NXT::Device* m_deviceRef;
	
	NxtOutput* m_outputA;
	NxtOutput* m_outputB;
	NxtOutput* m_outputC;
	NSArray* m_outputArray;
	
	NxtInput* m_input1;
	NxtInput* m_input2;
	NxtInput* m_input3;
	NxtInput* m_input4;
	NSArray* m_inputArray;
}

-(id) initWithDevice: (SBJ::NXT::Device*)theDevice;
-(SBJ::NXT::Device*) deviceRef;

// KVC Accessors
-(NSArray*) Outputs;
-(NSArray*) Inputs;
-(NSString*) Name;
-(void) setName: (NSString*)value;
-(BOOL) IsBluetooth;
-(BOOL) IsConnected;
-(NSString*) SessionName;
-(NSString*) ProgramName;
-(void) setProgramName: (NSString*)name;
-(NSString*) Version;
-(unsigned long) FreeSpace;
-(double) BatteryLevel;

// Commands
-(void) StartProgram: (NSString*)name;
-(void) StopProgram;
-(void) PlayToneAt: (unsigned short)hrz For:(double)secs;
-(void) SendMessage: (NSString*)str To: (int)box;
-(NSString*) GetLocalMessageFrom: (int)box Clear: (BOOL)clear;
-(NSString*) WaitForMessageFrom: (int)box Clear: (BOOL)clear;
-(NSString*) GetRemoteMessageFrom: (int)box Clear: (BOOL)clear;

@end
